package hu.myai.trade;

import hu.myai.api.trade.AbstractTradeManager;
import hu.myai.model.TradeVO;
import hu.myai.util.web.DownloadBigChartsPic;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * @author bozbalint
 *
 */
public class DummyTradeManager extends AbstractTradeManager {

    /**
     * The object used when logging debug,errors,warnings and info.
     * */
    private final Logger log = LoggerFactory.getLogger(this.getClass());

    private DownloadBigChartsPic bigChartsPic = new DownloadBigChartsPic(); 

    public DummyTradeManager(String name) {
        super(name);
        // TODO Auto-generated constructor stub
    }

    @Override
    public int buy(TradeVO trade) {
        // TODO Auto-generated method stub
        
        log.info("Do buy! (" + trade + ")");
        bigChartsPic.getPic("buy", trade.getSymbol(), trade.getDate().toString());
        return 0;
    }

    @Override
    public int sell(TradeVO trade) {
        // TODO Auto-generated method stub
        log.info("Do Sell! (" + trade + ")");
        bigChartsPic.getPic("sell", trade.getSymbol(), trade.getDate().toString());
        return 0;
    }

}
